#!/usr/bin/env python
# -*- coding: utf-8 -*-

import logging
from utils import response
from utils.decorators import api_view

logger = logging.getLogger(__name__)


@api_view(['GET', 'POST'])
def show(request):
    headers = {
        'Access-Control-Allow-Origin': '*',
        'Access-Control-Expose-Headers': 'X-Runtime',
        'Content-Type': 'application/json; charset=utf-8'
    }
    if request.command == 'GET':
        result = request.query_params
    else:
        result = request.data
    return response.response(result, headers)
